#include <iostream>
#include <iomanip>

using namespace std;

int main(int argc, char* argv[])
{
	cout << "n e"<<endl;
	cout <<"- -----------"<<endl;
	int n = 10;
	double *result = new double[n];
	int factorial = 1;
	for (int i = 0; i < n; i++)
	{
		if (i == 0) {
			result[i] = 1.0;
			factorial = 1;
		} else {
			factorial = i * factorial;
			result[i] = result[i - 1] + 1.0 / factorial;
		}
		cout<< setprecision(10);
		cout<<i<<" "<<result[i]<<endl;
	}
	delete [] result;
	return 0;
}